/**
 * 
 */
package game;

import java.awt.Frame;

import events.TickEvent;

/**
 * @author kasztan
 * 
 */
public class DisplayManager implements IClockListener
{
	static private DisplayManager instance;

	private Frame drawField;

	private DisplayManager()
	{
	}

	public void render(IImageContainer images) throws Exception
	{
		if(drawField == null)
		{
			throw new Exception("drawField not defined");
		}
		drawField.dispose(); //to remove
	}

	static public DisplayManager getInstance()
	{
		if (instance == null)
		{
			instance = new DisplayManager();
		}
		return instance;
	}

	public void setDrawField(Frame frame)
	{
		drawField = frame;
	}
	
	public Frame getDrawField()
	{
		return drawField;
	}

	public void onTick(TickEvent e)
	{
		// TODO Auto-generated method stub
		
	}


}
